
import events from 'events'
import util from 'util'

var GalleryAdapter = function () {
  events.EventEmitter.call(this)
}

util.inherits(GalleryAdapter, events.EventEmitter)

GalleryAdapter.prototype.registerObserver = function (callback) {
  this.addListener('on-changed', callback)
}

GalleryAdapter.prototype.unregisterObserver = function (callback) {
  this.removeListener('on-changed', callback)
};

GalleryAdapter.prototype.notifyDataSetChanged = function(state){
  this.emit('on-changed', state)
};

export default GalleryAdapter